Task 1)

The animation suggests that by swapping the edges the degree distribution gets closer to the theoretical distribution.

Task 2)

The output of lprun is in a popup window, which is not converted into html, so I attached it as a picture. lprun_popup.PNG

These graphs show us the number of edges, nodes and network diameter, when adding more and more layers to the network. One layer means the list of nodes, that is connected to the network's previous state. For example, in the beginning the network is only the elte.hu webpage, then we connect those pages to this node, which have a href on this webpage. Next we look at each newly connected webpage, and look for hrefs on them. Connect these new pages to the given page's node in the network.

We can conclude, that from about the 4th layer there is no substantial amount of nodes or edges added to the network. Other than that, the main goal was to show the diameter of the network while adding nodes to it. It is clearly visible, that the after that 4th layer the network diameter stops changing, it is stuck at 4.

Task 3